package top.spring.study;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import top.spring.study.service.AbstractInvoiceApplyStrategy;

import java.util.Map;
import java.util.Set;

@SpringBootApplication
//(scanBasePackages = "top.spring.study")
public class Application {
    public static void main(String[] args) {
        ConfigurableApplicationContext run = SpringApplication.run(Application.class, args);
        System.out.println("启动成功");


        Map<String, AbstractInvoiceApplyStrategy> beansOfType = run.getBeansOfType(AbstractInvoiceApplyStrategy.class);
        System.out.println(beansOfType);
        beansOfType.values().forEach(System.out::println);
    }
}
